package com.wpw.dream.frame;

import java.util.ArrayList;
import java.util.HashMap;
import java.util.HashSet;
import java.util.List;
import java.util.Map;
import java.util.Map.Entry;
import java.util.Set;
import java.util.TreeMap;
import java.util.TreeSet;

public class MapTest {
	public static void main(String[] args) throws InterruptedException {
		HashMap<Object, Object> map = new HashMap<Object, Object>();
		for (int i = 1; i <= 15; i++) {
			map.put(i + "", i + "");
			System.out.println(map.size());
		}
		
		Set<Entry<Object, Object>> entrySet = map.entrySet();
		
		HashSet<String> set = new HashSet<>();
		set.add("aa");
		
		List<String> list = new ArrayList<>();
		list.add("d");
		list.get(0);
		
		TreeMap<Object, Object> rm = new TreeMap<>();
		rm.put(new MapTest(), new MapTest());
		
		String[] strArray = new String[10];
		
		
	}
	public void inspect(List<Object> list) {
		for (Object obj : list) {
		System.out.println(obj);
		}
		list.add(1); //这个操作在当前方法的上下文是合法的。
	}
	
	public void add(List<?> list) {
		list.add(null);
		Object object = list.get(1);
	}
	
	public void add2(List<? extends Number> list) {
		
	}
	
	public void Test() {
		List<Number> list = new ArrayList<>();
		add2(list);
	}
	

}
